package com.zhao.dota.vo;

import com.zhao.dota.model.Hero;
import com.zhao.dota.model.Quotation;
import com.zhao.dota.util.SteamUtil;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@NoArgsConstructor
public class RollVo {

    private Integer id;

    private Integer userId;

    private Integer heroId;

    private Integer roundId;

    private String avatar;

    public RollVo(Quotation quotation) {
        this.avatar = SteamUtil.getIconUrlByHeroName(quotation.getHeroName());
        this.id = quotation.getId();
        this.userId = quotation.getUserId();
        this.heroId = quotation.getHeroId();
        this.roundId = quotation.getRoundId();
    }

}
